#include<Stdio.h>
#include<string.h>
#include<assert.h>

int my_strcmp(const char* str1, const char* str2)
{
	assert(str1 && str2);
	while (*str1 == *str2)
	{
		if (*str2 == '\0')
		{
			return 0;
		}
		str1++;
		str2++;
	}
	

	return *str1 - *str2;

}

int main()
{
	char arr1[] = "ab";
	char arr2[] = "abbd";
	int ret = my_strcmp(arr1, arr2);
	if (ret > 0)
	{
		printf("arr1>arr2\n");
	}
	else if (ret < 0)
	{
		printf("arr1<arr2\n");
	}
	else
	{
		printf("arr1 = arr2\n");
	}
	return 0;
}